package com.yz.gulimall.product.vo;

import com.yz.gulimall.product.entity.SkuImagesEntity;
import com.yz.gulimall.product.entity.SkuInfoEntity;
import com.yz.gulimall.product.entity.SpuInfoDescEntity;
import lombok.Data;
import org.checkerframework.checker.units.qual.A;

import java.util.List;

/**
 * @author yz
 * @create 2021-11-13 11:31
 */
@Data
public class SkuItemVo {
    SkuInfoEntity info;
    boolean hasStock = true;

    List<SkuImagesEntity> images;

    List<SkuItemSaleAttrVo> saleAttr;

    SpuInfoDescEntity desp;

    List<SpuItemAttrGroupVo> groupAttrs;

    @Data
    public static class SkuItemSaleAttrVo{
        private Long attrId;
        private String attrName;
        private List<AttrValueWithSkuIdVo> attrValues;
    }

    @Data
    public static class SpuItemAttrGroupVo{
        private String groupName;
        private List<SpuBaseAttrVo> attrs;
    }

    @Data
    public static class SpuBaseAttrVo{
        private String attrName;
        private String attrValue;
    }
}
